﻿@model IEnumerable<Modelo.Dominio.Cliente>

@section featured {
<section class="featured">
    <div class="content-wrapper">
        <hgroup class="title">
            <h1>@ViewBag.Title.</h1>
            <h2>@ViewBag.Message</h2>
        </hgroup>
    </div>
</section>
}

<p>
    @Html.ActionLink("Cadastrar cliente", "Create")
</p>
<table>
    <tr>
        <th>
            @Html.DisplayNameFor(model => model.Nome)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.CPF)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.RG)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Telefone)
        </th>
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.Nome)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.CPF)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.RG)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Telefone)
        </td>
        <td>
            @Html.ActionLink("Alterar", "Edit", new { id=item.Id }) |
            @Html.ActionLink("Detalhar", "Details", new { id=item.Id }) |
            @Html.ActionLink("Excluir", "Delete", new { id=item.Id })
        </td>
    </tr>
}

</table>
